package com.spirngcloud.alibabasentinelratelimiting.controller;

import com.alibaba.csp.sentinel.annotation.SentinelResource;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.core.env.Environment;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @version V1.0
 * @Author 宋聚智
 * @Date 2019/10/21 15:30
 * @description
 * @Modify By：
 * @ModifyTime： 2019/10/21
 * @Modify marker：
 **/
@RestController
public class SentinelController {
    @Autowired
    private TestSentinelService testSentinelService;

    @Autowired
    Environment env;
    @GetMapping("test/sentinel")
    @SentinelResource("testsentinel")
    public String hello(){
       String a= env.getProperty("abd");
        return "SJZ.com"+a;
    }




}
